Name:
disablebod
Syntax:

DISABLEBOD

Description:

Disable the on-chip brown out detect function.

Some PICAXE chips have a programmable internal brown out detect function, to automatically cleanly reset the chip on a power brown out (a sudden voltage drop on the power rail below the minimum operating voltage). The brown out detect is always enabled by default when a program runs.

However it is sometimes beneficial to disable this function to reduce current drain in battery powered applications whilst the chip is 'sleeping'. Use of the disablebod command prior to a sleep will considerably reduce the current drawn during the actual sleep command. However you must still ensure that the operating voltage does not drop below the minimum operating voltage or else unreliable behaviour may occur.

The brownout voltage is fixed for each device as follows:

1.8V 28X2-3V, 40X2-3V
1.9V 20X2, 14M2, 18M2, 20M2, 28X2, 40X2
2.1V 08, 08M, 14M, 20M, 28X1, 40X1
2.4V 08M2
3.2V 28X2-5V, 40X2-5V
None 18, 18A, 18M, 18X, 28A, 28X, 40X

The brown out detection can be re-enabled by a reset, or via the enablebod command.

Applies To:
All (except 08, 18, 18A, 18M, 18X, 28, 28A, 28X, 40X)
See Also:
Related Create:
Share:
Print:

Disabling brown out

This program will disable the brown out detection for 23 seconds then re-enable it.

Code Example:
main:	disablebod	; disable brown out
	sleep 10	; sleep for 23 seconds (2.3x10)
	enablebod	; enable brown out
	goto main	; loop back to start
Copy Code Submit an Example

Submit Your Own Code!

You must be logged in to submit code examples. Login now.