Jump to content
THIS IS THE TEST SITE OF EUROBRICKS! ×
THIS IS THE TEST SITE OF EUROBRICKS!

Recommended Posts

Posted

Hm... that's not right! :wacko: On what model of phone are you running the app? Does it do the same thing for the momentary controller?

Your HE looks great, nice and zippy like a high speed train should be. :thumbup: Can't wait to see it on 10.8V!

My PCBs should get back from the fab tomorrow. I'm looking forward to getting them up and running, so I can make sure the firmware is in tip-top shape. I have some time to wait for the BT modules, but I have a single one that I can use for debugging in the meantime.

The momentary controller only shows the 2 check boxes :( The phone is a Nexus 5 running stock 4.4.3. My guess is screen resolution, my phone is 1080p.

I already have everything except the PCB itself, so you can imagine I'm getting antsy :)

  • Replies 130
  • Created
  • Last Reply

Top Posters In This Topic

Posted

The momentary controller only shows the 2 check boxes :( The phone is a Nexus 5 running stock 4.4.3. My guess is screen resolution, my phone is 1080p.

I already have everything except the PCB itself, so you can imagine I'm getting antsy :)

It probably is a screen resolution issue. I'll look into it.

From where did you buy your BT modules? If you've received them already, I ought to order mine from there in the future!

Posted (edited)

I got mine from here: http://r.ebay.com/lAut0p

He also had a listing for a master version instead of slave.

Nice find. :thumbup: The master version has an incompatible pin-out, though it is literally the same hardware running a different firmware.

I received my BT modules yesterday. Just under two weeks, not bad. I must have ordered during a holiday or something last time. I recall it taking near a full month to arrive.

I've also been researching a new BT module (with mostly the same pin-out). It offers dual mode BT 2.1/4.0, so there's potential for an iOS app if using that module (HM-12). The current module can only support Android (and NXT, EV3, PC, etc). Silly Apple and their costly1 MFi program :hmpf_bad:

The momentary controller only shows the 2 check boxes :( The phone is a Nexus 5 running stock 4.4.3. My guess is screen resolution, my phone is 1080p.

Can you give this version a try? (You may need to uninstall the old version first.) https://www.dropbox.com/s/xek4e78etbzdbql/BricksTer-last-working-06.apk I've only changed the momentary controller yet. (I didn't think until I was finished that I should have done the speed controller first!) This may or may not fix it, but it's been something I've been meaning to figure out for a while now. If it doesn't fix it, I have another idea.

1 It costs money to develop with MFi, PCB space to fit their manditory IC, and firmware bloat to implement their special protocol. Bluetooth 4.0 operates outside the MFi program, but is not supported by Android (yet), NXT, EV3(?), etc.

Edited by codefox421
Posted

Can you give this version a try? (You may need to uninstall the old version first.) https://www.dropbox....-working-06.apk I've only changed the momentary controller yet. (I didn't think until I was finished that I should have done the speed controller first!) This may or may not fix it, but it's been something I've been meaning to figure out for a while now. If it doesn't fix it, I have another idea.

Bluetooth 4.0 operates outside the MFi program, but is not supported by Android (yet), NXT, EV3(?), etc.

Still the same, no graphics, only checkboxes. Does it matter that I'm not actually paired with any BT devices at the moment? And are you sure that Android doesn't support BT4.0? My Nexus 5 has a BT4.0 chip: http://www.gsmarena.com/lg_nexus_5-5705.php

Posted (edited)

And are you sure that Android doesn't support BT4.0? My Nexus 5 has a BT4.0 chip: http://www.gsmarena....exus_5-5705.php

There is definitely some hardware that supports it, but there isn't support in the Android API yet. Plus, I would think NXT/EV3 compatibility is a necessity for a LEGO-compatible device! :laugh:

Anyway, I'll take another look at the app. Might be as simple as the image being too large, but then I'd think it wouldn't work on my phone either... hm...

Still the same, no graphics, only checkboxes. Does it matter that I'm not actually paired with any BT devices at the moment?

Being paired doesn't matter. Here's another try at resolving this: https://www.dropbox....-working-07.apk

Thanks for working with me to clear this up. =)

EDIT: There's a bad bug in that binary. I've fixed it and sent you a new link in a PM. It's probably best to debug outside this thread as there may be lots of back and forth to get to the bottom of this disappearing act.

Edited by codefox421
Posted

UguqNELh.jpg

qIgeX5fh.jpg

This is my second attempt for which I used my reflow gun. The first I used my iron, which doesn't look nearly as pretty.

Still working through some firmware bugs, I can pair my phone with it, but am still unable to control motors correctly.

Posted (edited)

This is my second attempt for which I used my reflow gun. The first I used my iron, which doesn't look nearly as pretty.

Still working through some firmware bugs, I can pair my phone with it, but am still unable to control motors correctly.

Looking good. :thumbup: I've finished soldering my first board this morning. I'll post pictures later.

EDIT:

brickster-pcb-0163.jpg

brickster-pcb-0167.jpg

I can only test one channel at a time since I only have one spare PF lead. I'm testing the red channel right now (A in the firmware). I'm seeing it function properly when going forward, but the speeds seem to be reversed (i.e. 0-7-6-5-4-3-2-1) when going backward. I'm sure it's a firmware bug; just a matter of tracking it down. I expected to find some bugs as these are the first tests with the new board layout.

EDIT: It was a super simple fix once I found it. I had forgotten to uncomment two lines that are necessary for the DRV8833 motor driver chip. Silly me. :blush:

Working firmware is now checked into the new repository.

Btw, I've split the repository into two, one for the android app and one for the hardware/firmware: https://github.com/BTbricks

Edited by codefox421
  • 3 weeks later...
Posted

legoman and I got the kinks worked out, and he will be taking two receivers with him to BrickFair Virginia!

While working with legoman, I realized the biggest failing of the BricksTer project has been the lack of documentation for getting started.

Today, I'm proud to present BricksTer's first ever detailed, step-by-step Readme and How-To Guide! View it here in the repository.

By the way, I calculate the cost of materials per device is about $26 USD.

Posted (edited)

How did the fabbed boards go? Everything program ok?

Never mind that ^ that's what I get for trying to read at work and only looking at the first page of posts...

Edited by OzShan
Posted

How did the fabbed boards go? Everything program ok?

Never mind that ^ that's what I get for trying to read at work and only looking at the first page of posts...

It's good to know I'm not the only one who visits eurobricks at work! XD

If you have any questions or suggestions, please post them. Let me know if you are building your own copies. I like to know that others are benefiting from my work =)

Posted

Glad to help debugging. Of my first set of 3 controllers, 2 work great! I think I killed the BT chip on the third. I've already ordered the parts for 6 more. The first two will be making an appearance at Brickfair VA Auguest 1st.

No line of sight = awesome. Also, if you are tired of trying to hide the bulky Lego IR receiver, this is for your. It's only a couple mm thick and about 1.25x1.25".

Posted

No line of sight = awesome. Also, if you are tired of trying to hide the bulky Lego IR receiver, this is for your. It's only a couple mm thick and about 1.25x1.25".

That's 4x4 for those counting in studs. :wink:

The electronics only take up 3x4, the extra row of studs is to allow room on the PCB for mounting holes. Those would disappear for an enclosed version, and the traditional technic holes in the end could be added with a simple 1x4 technic brick.

Now to actually design a case... along with improvements to the app, firmware, etc. It's a lot for one developer and one beta tester (with real jobs on the side)! We definitely appreciate any help we can get! :)

Posted

This is looking really good! I can see a lot of work has gone into this.

I'm not too familiar with Bluetooth versions, but will this work with older phones?

If you need help designing a case that is my specialty, I'm a professional 3d modeller with a decade now of experience, and of course I love Technic. :tongue:

Posted

This is looking really good! I can see a lot of work has gone into this.

I'm not too familiar with Bluetooth versions, but will this work with older phones?

If you need help designing a case that is my specialty, I'm a professional 3d modeller with a decade now of experience, and of course I love Technic. :tongue:

Thank you!

Yes! BricksTer is compatible with older phones, as well as NXTs, PCs, and EV3s*.

I would love getting your help to design a case! I have a handful of ideas about the direction I'd like to take it, but it's pretty much a clear slate right now.

Setting this up might be easier done through voice than text. Do you use Skype or some other VoIP service? PM me please. :sweet:

*Based on specs and not real world tests. I don't own an EV3, so I can't test with one. Anyone have an EV3 and want to help out? Let me know!

Posted

...

I'm seeing it function properly when going forward, but the speeds seem to be reversed (i.e. 0-7-6-5-4-3-2-1) when going backward.

...

If you're not using the existing IR transmitter or receiver on either end and don't need to keep compatibility, why keep the stepped power outputs limited to only +/-7 levels? It would make for smoother acceleration and turning if you split it up over a wider range wouldn't it, or have I missed something?

I don't understand why they limited themselves in the original protocol either. Couldn't wait a few milliseconds to transmit a couple of extra bits?

Posted (edited)

The original plan was for BricksTer to be a 1:1 replacement for the IR receiver. Since then, plans have changed and there are now 28 (=7*4) speeds in each direction (edit: that's a total of 56 + brake/float) . However, they are only accessible via the direct-to-speed message mode. There is another message mode which acts like the 1:1 IR replacement.

I'm not sure if things will stay like this forever; I've been toying with the idea of adding an oscillator, so the uC can run at a higher clock speed, and I can pass off the PWM generation responsibilities to the built-in comparators. Currently, any communication interrupts the PWM signal, so I've limited messages to 1 byte. This limits the resolution of the speeds, but 28 is decently fine-resolution for what is essentially a toy.

I ought to make a video demonstrating the finer-than-7 resolution...

Edited by codefox421
Posted (edited)

How can I modify my firmware to use the finer stepping? I saw that the array holding the pwm values had 28, but I didn't really make the connection until now.

The `comboMode` function, specifically when `maskedByte == upX` or `maskedByte == downX`, is where the speed controller logic happens. You can rewrite these sections to take finer steps with the virtual speed controller.

Alternatively, your direct-to-speed sliders already use the finer resolution. :wink:

Edit: For anyone interested, here's the APK with those sliders: https://www.dropbox....ann-sliders.apk They are buried in the menu at the upper-right of the screen. Kinda messy I know, but a massive overhaul of the app is in the development stages...

Edited by codefox421
Posted

Thanks for the update. 28 is far better than 14. Anything that can be bumped off to dedicated hardware will operate very well, but no need to battle with it just for the sake of it.

Posted (edited)

Thanks for the update. 28 is far better than 14. Anything that can be bumped off to dedicated hardware will operate very well, but no need to battle with it just for the sake of it.

If you think of the IR receiver as having 14 speeds, then BricksTer has 56! It is 28 in each direction. :wink:

I have to do more research, but I'm working toward the ability to upload the firmware wirelessly over the Bluetooth link. It's looking like this will require the use of a more feature-full microcontroller, but that's good news for offloading PWM (and serial) to hardware!

Also, Doc and I had a good chat last night. I'm looking forward to see what he comes up with for the case. :classic:

Edited by codefox421
  • 4 weeks later...
Posted

No worries OzShan!

I've got great news: Doc and I had some productive discussion and he provided an excellent mockup of a case! I went on to make some modifications, and the 3d file is now hosted in the repository: https://github.com/B...kster8884bt.stl (The interactive preview shows some invisible faces on the inside of the bottom half, but they do exist. I think the normals are backward.)

I had the prototype 3D printed from Shapeways, and put together this little video update:

In summary:

  • Dimensions: 3 x 4 x 1 2/3
  • Input: 1 on bottom
  • Output: 2 on top
  • Technic holes: added externally (can make holes face sides, or use axle holes, etc)

I really appreciate any feedback I can get about the current case design.

Please let me know what you like and what you don't like.

Do you think BricksTer needs a case at all? :laugh:

As a last note, I had to really hack the PCB to get it to interface with the enclosure. Even now it can still be a little uncooperative at times. This is understandable; the current PCB wasn't designed to be put in a box! I plan to make another revision of the PCB and design it with this in mind.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.

Announcements

  • THIS IS THE TEST SITE OF EUROBRICKS!

×
×
  • Create New...