BeagleBone Black RTC?

Hello,

I've ust had a look at the specs for BeagleBone Black.

As usual, my first question was: Does it support RTC operation?

Having a first look at the schematics, it does not look like it is possible to connect some coin battery or similiar to drive the processor in RTC only mode. Am I right and this another non-RTC design which needs an external RTC connected to I2C or similiar?

Regards,

Alexander

Some circuitry and a (small) connector to be able to use one of those widely available small LiPo's (as used in the model making world to power those small helis and similiar) would have been very nice too.

Regards,

Alexander

Same as Beaglebone. No RTC battery capability.

Gerald

These documents are correct. In fact, I know the author fairly well.

Yes, you can add the battery if you chose to. But, the SW needs to be there to support it. Also, you need the SW to put the PMIC to power down mode and shut everything down and not to turn off the power.

So. add the battery and you will see that the RTC function, does not work. You will need to add that support to the SW.

So as I said, No RTC support, just like, the BeagleBone.

Gerald

Hi all,

If one adds the feature in software, would it be physically possible to have the realtime clock feature (with wake up events etc) if it is done correctly in software?

Is the software implementation the only thing stopping RTC functionality (besides needing to connect a battery to the power management chip)?

Fisher

or just purchase a RTC Cape

http://elinux.org/CircuitCo:RTC_Cape for $29.99MSRP

Hi David,

Yes, I have also seen small boards from Adafruit, though if I need an RTC and it is possible to implement a fully functional one with the current board by just adding a battery, I wouldn’t add any extra components, especially since the RTC in the CPU seems to have wake up events.

I am doing a Masters project in control systems at university and am hoping to either not have any external boards or at least very minimal.

I will probably make my own board and won’t add an RTC if I can implement one with what is already on the BBB, especially as it may have more features such as wake ups which a general I2C RTC won’t have I don’t think.

Fisher

Fisher,

good luck, as Gerald said, making it work is going to be an extreme challenge, which is why we specifically created the RTC Cape.

Dave

External RTC is the best solution. You could add a battery to the BBB and use it with the right SW. But, depending on how many days you want it to hold time, it may or may not work for you.

Gerald

Hi Dave and Gerald,

I don’t have one of these boards yet so just wanted to check as I am assessing the BBB and comparing it to others for my university project.

If it is physically possible to add a rechargeable battery to the PMIC for it to power the board and be charged when external power is connected, that is a bonus that the BBB has on board battery charging (I assume only for low capacity LiPos like 800 mAh etc).

If the that battery also allows one to use the RTC within the Ti CPU as the RTC was intended which is to my knowledge to keep track of time (with calendar) and to wake the CPU up with events, then surely that means there is included RTC functionality if the SW is done correctly?

If one just needs to add some commands to a shutdown script for this to all work once the battery is added then its another justification in my report.

Am I off track? Gerald, was your only issue with that the battery capacity between charges? Is the SW just sending low level sleep commands to the CPU after kernel/OS has gone through some sleep or shut down process and I2C to the PMIC?

I haven’t checked the power management chip docs or details of the AM355x to know the shutdown/sleep process for an RTC wake etc.

I’ll look into it if I get one.

Fisher

or just purchase a RTC Cape

http://elinux.org/CircuitCo:RTC_Cape for $29.99MSRP

Thanks, but I already have fully working hot-pluggable USB-RTCs I can use with almost all RTC-less boards I have.

But you might have an interesst in some patches I've written to use them. They will make it possible to use the RTC-drivers as modules (and the time still will be set automatically by the kernel), besides to choose by kernel-command-line which RTC driver will be used:

https://lkml.org/lkml/2014/6/13/6

Unfortunately they will likely never end up in mainline.

Regards,

Alexander Holler

Hi,

I just managed to put the PMIC in SLEEP state, and the AM335x in RTC_Only state. It has been done using u-boot, based on Matt (https://groups.google.com/d/msg/beagleboard/K7DuusrJ6G4/unH1m5HpiuoJ) explanation:

U-Boot# i2c mw 24 a 00
— Send 0x00 to PMIC

U-Boot# base 44e3e000
Base Address: 0x44e3e000
— Set RTC registers as base address

U-Boot# mw 98 10011
— Program RCT_PMIC register as PMIC_Power_EN enable, wakeup event enabled, and active low

U-Boot# mw 48 10
— Set alarm2 as interrupt

U-Boot# cp 8 88 4
— copy actual hour to alarm2 hours

U-Boot# md 0 2
44e3e000: 00000056 00000044 V…D…
— read actual second/minute (56/44)

U-Boot# mw 84 46
– set minute 46 as alarm2 trigger

And wait until it is powered off. A pmic wakeup event (AC on, for example) will wake up the whole Beaglebone.

Regards!

edugalvez,

I must have missed that post, or the post predates me on these groups. Thanks for sharing, this is very good to know. Truly.

On the other side of the coin, how is this useful once you’re running Linux ? Perhaps /dev/mem ?

William, don’t know yet :).

Information about this topic was confusing, so first step was to prove that the BBB and a Li-Po battery can keep the RTC alive.

Ok. I was not trying to be smart, but was curious. I am still learning a lot about the beaglebone black myself, AND we’re offgrid here ( solar and wind ) so this kind of topic generally peaks my interest.

did you manage to implement RTC whith BBB regards

This is one way:

http://elinux.org/CircuitCo:RTC_Cape

Otherwise grab any i2c/rtc adapter board off sparkfun, (3.3v) and wire to
the i2c..

Regards,

in my custom board, i used an external i2c RTC chip, proven to be reliable and inexpensive.

I've build me USB-RTCs to use them with different boards:

http://ahsoftware.de/dcf77-hid-usb-rtc/
http://ahsoftware.de/usb-rtc/

Alexander Holler

I’ve build me USB-RTCs to use them with different boards:

http://ahsoftware.de/dcf77-hid-usb-rtc/
http://ahsoftware.de/usb-rtc/

+1

Looks like you’ve been busy yet again Alexander . . . very interesting reading :slight_smile: