RetroBSD

2.11BSD operating system for microcontrollers
It is currently Wed Jun 19, 2019 1:47 pm

All times are UTC




Post new topic Reply to topic  [ 8 posts ] 
Author Message
 Post subject: halt and reboot problem
PostPosted: Fri Oct 16, 2015 12:32 pm 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
halt and reboot - crashes - loops through login.

_________________
Pukao Hats Cleaning Services Ltd.


Top
 Profile  
 
PostPosted: Fri Oct 16, 2015 1:04 pm 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
Wait long enough and it finally gets there.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Fri Oct 16, 2015 3:51 pm 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
:D
We need halt in 1-2secs.

_________________
Pukao Hats Cleaning Services Ltd.


Top
 Profile  
 
PostPosted: Fri Oct 16, 2015 4:58 pm 
Committer
User avatar

Joined: Thu Oct 11, 2012 8:45 am
Posts: 1801
Location: Room 217, Floor 8, Arm 8, Wheel S7, Mars Base Alpha 3
I think the problem is that `init` doesn't know that it shouldn't be respawning the getty processes while it's shutting down.

The simple solution is to use `reboot -q` etc.

_________________
Why not visit my shop? http://majenko.co.uk/catalog
Universal IDE: http://uecide.org
"I was trying to find out if it was possible to only eat one Jaffa Cake. I had to abandon the experiment because I ran out of Jaffa Cakes".


Top
 Profile  
 
PostPosted: Sat Oct 17, 2015 1:42 am 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
Pito wrote:
We need halt in 1-2secs.

Typically, TCP network connections need at least 2 sec to terminate gracefully. Halt utility could query whether open sockets are present, and choose a proper timeout.


Top
 Profile  
 
PostPosted: Sat Oct 17, 2015 6:44 am 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
Serge - 1 or 2 o 3 secs - that does not matter - but we really need a functionality where a hw signal at a pin triggers for example "halt" for a graceful termination. For retrobsd even more. Pulling a plug may easily corrupt the data on the sdcard. With a standalone apps based on retrobsd it is vital.

_________________
Pukao Hats Cleaning Services Ltd.


Top
 Profile  
 
PostPosted: Sun Oct 18, 2015 8:47 am 
Contributor
User avatar

Joined: Thu Nov 08, 2012 7:04 am
Posts: 2401
Location: Rapa Nui
Works nice now!
The next step is the hw trigger :)

_________________
Pukao Hats Cleaning Services Ltd.


Top
 Profile  
 
PostPosted: Sun Oct 18, 2015 6:57 pm 
Committer
User avatar

Joined: Wed Oct 10, 2012 11:01 pm
Posts: 1081
Location: Sunnyvale, CA
HW trigger will need a bit more effort.
The idea is to allow any process to get a software signal, like SIGALRM or SIGUSR1, when some hardware GP inputs change. A kernel data structure for every process (struct mdproc) needs to be extended with bitmasks for all GPIO ports (PORTA...PORTK). The gpio driver should poll by timer for pin changes, like every 100msec. In case the changed input pin matches the process bitmask, this process gets a software signal. Something like this.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 8 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
cron




Powered by phpBB® Forum Software © phpBB Group

BSD Daemon used with permission