livebox:hah_microcontroller

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
livebox:hah_microcontroller [2011/12/18 23:39] – [Command Interface] brettlivebox:hah_microcontroller [2012/06/05 15:53] (current) – [Microcontroller firmware] brett
Line 1: Line 1:
 ====== Microcontroller firmware ====== ====== Microcontroller firmware ======
  
-The microcontroller firmware for the AVR is written in C using the [[http://www.arduino.cc/|Arduino]] IDE.  Firmware revisions before v3.x where written in [[http://www.mcselec.com|BASCOM]].+The microcontroller firmware for the AVR is written in C using the [[http://www.arduino.cc/|Arduino]] IDE. 
 + 
 +^^ Chip ^^ Firmware ^^ Language ^^ 
 +|| ATmega8 || 1.0 || [[http://www.mcselec.com|BASCOM]]|| 
 +|| ATmega328P || 2.x || [[http://www.mcselec.com|BASCOM]]|| 
 +|| ATmega328P || 3.x || C || 
 + 
 + **The current release is v3.4** 
 + 
 +On the top RHS of every HAH web UI page, you will see 'Build: vvv.v/x.x' 
 + 
 +vvv.v is the HAH firmware build. x.x is the AVR code version. 
 + 
 +You can force the xap-livebox program to communicate at a specific version if auto detection of the AVR firmware version is failing using the following setting in your /etc/xap-livebox.ini file. 
 + 
 +<code> 
 +[hardware] 
 +major=3 
 +minor=4 
 +</code> 
 ===== Command Interface ===== ===== Command Interface =====
  
Line 8: Line 28:
 We communicate at 115200 baud as this is the default speed for the Livebox serial interface.  This also affects the XTAL we need to choose for the hardware.  7.3728Mhz gives us the most accuracy at this baud rate. We communicate at 115200 baud as this is the default speed for the Livebox serial interface.  This also affects the XTAL we need to choose for the hardware.  7.3728Mhz gives us the most accuracy at this baud rate.
  
-The HAH firmware normally runs a process named xap-livebox to connect to the HAH PCB. If you want to connect manually for debug, be sure to kill off the xap-livebox process first.   ''# killall xap-livebox''+The HAH firmware normally runs a process named xap-livebox to connect to the HAH PCB. If you want to connect manually for debug, be sure to kill off the xap-livebox process first. 
 + 
 +<note important>The usage information here is for the ATmega328 firmware.\\  The ATmega8 does not have a visible command line even thou access is possible this way too.</note>
 <code> <code>
 +# killall xap-livebox
 # microcom -s 115200 /dev/ttyS0 # microcom -s 115200 /dev/ttyS0
 +++         <--- depending on the state of the AVR you might need to jump it past the BOOT wait stage +++         <--- depending on the state of the AVR you might need to jump it past the BOOT wait stage
Line 94: Line 117:
 ==== on / off ==== ==== on / off ====
  
-Toggle a relay or RF relay from the on to the off state.+Toggle a relay on/off.
 <code> <code>
 >on 1 >on 1
Line 100: Line 123:
 </code> </code>
  
 +For the M8 firmware this was also overloaded to control RF devices.  This was replaced in the 328 firmware with [[universalrf]]
 +<code>
 +> on 5
 +</code>
  
 +The 1st RF sequence saved into EEPROM would be addressable as 5, the 2nd as 6 etc..
 ==== lcd ==== ==== lcd ====
  
  • livebox/hah_microcontroller.1324251576.txt.gz
  • Last modified: 2011/12/18 23:39
  • by brett