Hi Pete,
> 1. the hardware side (ultimately the energy monitor stuff)
> 2. the C code (sketch) on the Arduino MCU
> 3. the AutobahnPython/Twisted/Python bridge running on Yun Linux
> 4. the JS/HTML5 running in browser (which involves AutobahnJS)
>
> Am I right that you're definitely covering 1. + 2. in your teaching
> (and you can assume sufficient knowledge/effort in that with your
> students)?
>
>
> Right. at this moment, they are about half the way through the
>
codeacademy.com <
http://codeacademy.com> python course, which I have
> finished. I'm also used to coding from way back in the 1970's when I
> used punch cards! So the students will have a basic understanding of
> python. After they finish the python, we'll play around with the arduino
> until they have a basic handle on the hardware and the software.
Python .. Codeacademy .. sounds like a good start!
Since you mention "punch cards" .. I've never did anything like that -
me, I started like age 12 on a 8 bit MCU (CDP1802) with machine code /
assembly - it was a hard, but good experience;) Moved on to Apple II
(Motorola 6502), Commodore C64, Amiga etc
Besides C vs JavaScript vs Python on a _language_ level, there is 1
major difference:
The MCU programming on the Arduino in C is in a _synchronous_ style:
like do A, then B, then wait N ms, then loop again.
Both the networking programming with Autobahn/Twisted in Python and the
UI/network programming in JavaScript in the browser follow a
fundamentally different style: _asynchronous_ event driven programming.
That is, I hook up an event handler (a piece of code), that will get
fired _by the framework_ when something specific happens. A button is
clicked. A message arrives from the network. Etc.
This difference in style I'd say is larger and probably more fundamental
than any difference between Python and JavaScript (and probably even to
C .. where there are asynch. frameworks also).
An introduction to asynchronous (network and/or UI) programming is
probably a course in itself. It's a whole world on it's own. Just wanted
to say ..
But I agree: some "basic" understanding, and tinkering around with
modifying sample code is possible nevertheless ..
>
>
>
> I am unsure about 4., and even more about 3. ..
>
> Do you want to go into JavaScript, HTML5 etc?
>
> Do you want to go into Python .. and Twisted asynchronous network
> programming etc etc
>
> Especially 4. might be a challenge. You know, it's not rocket
> science, but you need _some_ background, otherwise it'll be mostly
> cryptic.
>
>
> I agree that they won't be able to follow on too much with the details
> of the actual code, but they can get a sense of what we are doing, and
> perhaps be able to modify the code to check more than two pins, etc. I
> might be able to get most of it. I can ask you specific questions about
> the python code.
>
>
>
> In essence, to master the programming for the demo as of now, you
> need to have knowledge in C, Python and JavaScript.
>
> Regarding the way forward: the goal with SRDP/Crossbar.io would be
> to get rid of any custom programming (based on raw Autobahn) for 3.
>
> "Just" install Crossbar.io on Yun Linux, and then you can
> concentrate to 1/2 (and 4).
>
>
> Well, the Crossbar.io implementation sounds too good to be true! That
If only a day had 48h .. or we had more development man power .. since:
it's clear how to do it, we have all the basic blocks already, but yes,
it's still a lot of detail work ..
> would rocket us forward into the 21st century, no?
Yes, I agree (obviously) =)
/Tobias
>
> Pete
>
>
>
>
> On Sun, Dec 1, 2013 at 9:05 AM, Tobias Oberstein
> <
tobias.o...@gmail.com <mailto:
tobias.o...@gmail.com>> wrote:
>
> Am 01.12.2013 05:45, schrieb Peter Kalajian:
>
> Tobias,
>
> How about adding a slider like
>
http://www.dyn-web.com/code/__slider/
> <
http://www.dyn-web.com/code/slider/> to
> send data to analogwrite to a digital pin for PWM? That would be
> a good
> feature for the robotics types to control motors.
>
>
> Yes, this can be done trivially. I'd recommend to go with the new
> HTML5 slider element:
>
> <input type="range">
>
>
http://www.html5tutorial.info/__html5-range.php
> <mailto:
aln...@gwi.net <mailto:
aln...@gwi.net>>> wrote:
>
> Tobias,
>
> It works! Fantastic.
>
> one change: You give the ip address for your yun. Need to
> remind
> folks to put their ip or just my_arduino_name.local:8080.
>
> what does commenting out the inittab line do?
>
> What next?
>
> Pete
>
>
> On Sat, Nov 30, 2013 at 3:23 PM, Tobias Oberstein
> <
tobias.o...@gmail.com
> <mailto:
tobias.o...@gmail.com>
> <mailto:
tobias.oberstein@__
gmail.com
> <mailto:
tobias.o...@gmail.com>>> wrote:
>
> OK, all done. Waiting for the next instructions.
>
>
> Hi Peter,
>
> alright, the real-time charting demo ("serial2ws") now
> runs on
> the Yun.
>
> Added a video to the beginning of
>
>
http://tavendo.com/blog/post/____arduino-yun-with-autobahn/
> <
http://tavendo.com/blog/post/__arduino-yun-with-autobahn/>
>
>
> <
http://tavendo.com/blog/post/__arduino-yun-with-autobahn/
> <
http://tavendo.com/blog/post/arduino-yun-with-autobahn/>>
>
> and a section "Running the Demo" at the end. It has all the
> steps, though isn't very elaborate, polished or nice .. but
> should be enough so you can do some experiments on your
> Yun also.
>
> The hard questions are now all answered;) It works.
>
> Now, we can go on with SRDP / Crossbar.io ..
>
> Cheers,
>
> /Tobias
>
>
> --
> You received this message because you are subscribed to
> a topic
> in the Google Groups "Autobahn" group.
> To unsubscribe from this topic, visit
>
https://groups.google.com/d/____topic/autobahnws/B3L4N2J7Jac/____unsubscribe
> <
https://groups.google.com/d/__topic/autobahnws/B3L4N2J7Jac/__unsubscribe>
> to autobahnws+unsubscribe@__
googl__egroups.com
> <
http://googlegroups.com>
> <mailto:
autobahnws%__2Buns...@googlegroups.com
> <mailto:
autobahnws%252Buns...@googlegroups.com>__>.
> For more options, visit
>
https://groups.google.com/____groups/opt_out
> <
https://groups.google.com/__groups/opt_out>
> an email to autobahnws+unsubscribe@__
googlegroups.com
> an email to
autobahnws+...@googlegroups.com.