« Archives in October, 2011
30
October

The Week of Videos

As some of you may have seen, I did a ‘week of videos’ on my Facebook profile. To those that didn’t get to see it, or can’t see it (since you don’t use Facebook, or don’t have me as a friend), you’re not forgotten! Here is the full list:

Sunday:

Monday:

Tuesday:

Wednesday:

Thursday:

Friday:

Saturday:

Enjoy, everyone!
Robert

28
October

Weekly catchup – Week eighteen

Welcome to the last (official) week of this series for 2011! I will do an exam edition, like I did at the end of last semester, but this will be all for the year. I don’t know whether I will continue this series next year either. If anyone would like me to continue this next year, post in the comments below. Moving on, I’ve been meaning to post more this week, since my group project basically finished on Tuesday, but I felt like leaving that discussion until now. So I’ll get right into it.

Monday: I went into university to meet up with my group and prepare what we were doing for the presentation the next day. We didn’t spend too much time there, just basically ran through what needed to be talked about and what we were going to do with the demo (since our Robot turned out so bad). Basically everyone left straight after that, so I decided to just work on my research report for the group project. By the time I left, a fair bit of it was done (but it still needed a fair bit added). I was able to complete it during the night at home, which I was proud of.

Tuesday: Presentation day! It was still an early morning, as usual, but it wasn’t as bad as our weekly meetings. When I got into university, I started preparing the Robot and making sure it was ready to do at least something. At nine we had a SELT (Student Evaluation of Learning and Teaching) session for the group project. I surprised myself by giving a fairly moderate review (compared to a bad one that I wanted to give). After that, my group had 20 minutes to spare before the actual presentation. In that time, we were able to finish the preparation on the Robot demo and the process presentation (the major part of the marks). The presentation went very smoothly. We were even able to make one of the ‘clients’ (lecturers) laugh! That made me happy. Then we did the demo, and everything felt like it went downhill. Turned out it didn’t though, since after finishing the demo, packing up and leaving the room, we asked one of the lecturers how we went (informally), and they said we don’t need to worry. At eleven I left to catch up with a friend for a little while. We mainly just chatted about random things. It was good. A bit before one we parted ways, since they were going to catch up with another friend. I just went to the BESE lab to work on my DS assignment. In the time I was there, the other SE group turned up after their presentation. Turned out they believed they did just as well as my group.

Wednesday: I decided to go in a bit earlier than usual on Wednesday, to destroy my group’s Robot and chat a bit with the guys in the other SE group. It was pretty fun, ripping apart all the rigging we’d used to ensure nothing moved unless it was supposed to. And listening to all the sound effects one of the guys was playing was pretty funny too. At two some of us went to the DS review lecture (after putting the robot kits away and giving the keys to the office). It was actually a pretty good lecture. I paid attention basically the whole time. It only lasted an hour, though. So that helped. After the lecture, I just went home.

Thursday: The last early morning for this year!! The OS lecture in the morning wasn’t too bad. It was just more on file systems, and stuff like that. I didn’t completely pay attention. After the lecture, my group met up to try and finish up the documentation for the project. We were able to get nearly everything up to date, except for some small things that still needed fixing. While one of the guys was working on the document (after the other two that turned up had left), I did a little work on my DS. I wasn’t in much of a mood to do too much, though. We also found out that we were supposed to get the robot kits checked by someone and give the keys to them. Thankfully, they’d gotten the keys, so we were able to get the kit back out and checked off properly.

Friday: Today is the first day in weeks I’ve been able to have a decent sleep in! I didn’t get up until eleven. I didn’t do too much during the day, either. Just worked on finishing my DS, and did one final clean up of all my group’s documents before sending them off to the lecturers. It felt good to get everything completed and sent off. Don’t need to worry about anything else but exams now.

That’s my week completed. Thanks for reading.
Robert

22
October

Weekly catchup – Week seventeen

Hey all. Welcome to my hell of a week. Sorry if things seem a bit light, but there isn’t too much to be said. Anyway, I’ll get straight into it.

Monday: I went into university to work on the Robot with everyone else in my group. Firstly we discussed what we needed to talk about in the meeting the next day (the ethics presentation), before getting stuck into a fair bit of coding and documentation work. It seemed like we had a fairly stable Robot by the end of the day, even though it was still very buggy (yeah, I know that’s a contradiction).

Tuesday: Early morning 1, in the ethics presentation meeting the group did awesomely! First meeting we’ve ever done well in. We weren’t perfect, though. After that presentation, we went straight into more coding and documentation work. But all we seemed to be doing was making things worse.

Wednesday: I went in earlier than usual to meet up with a friend and give them some help with one of their projects. Turned out I wasn’t as helpful as expected, but oh well. It was nice to catch up for a while. In my lecture for the day, DS, we had a guest lecturer from Google. It was a really interesting lecture about how Distributed Systems are used within read-world systems.

Thursday: Early morning 2, started out with my OS lecture. It was actually a fairly good lecture compared to most others. The lecturer even cracked a few jokes (which made the majority of the class laugh). The lecture was mostly just more about file systems and the underlying hard drives. After the lecture, my group met up once again to work on the project. The majority of my time was spent on documentation or debugging the Robot with one of the other members. Unfortunately, I somehow uploaded a wrong version of the document we needed to work on for the day. We were able to fix it, but it took a while. We also found out the Robot’s somehow developed a memory leak.

Friday: Another day at university, even though I wanted to have it off. Only two of us turned up, which made things hard to work with. Seriously killing me. We got some bits of the code working better, but not enough. The GUI was pretty close to complete, though. Later in the day I had my collaborative session for DS. That was a joyful experience. We had to design a MMORPG system. I think my group came up with a fairly good solution (which still needs to be completed). After that session, I went back to the project group member that had turned up (since he was still working on it) and found out what he’d done.

That’s pretty much my week (except for today – I also went into university for eight hours). We made little to no progress on the actual Robot, but the GUI is pretty much complete. Thanks for reading.
Robert

18
October

Reaper Quicky #15

Just a quick update for everyone – today in my group’s client meeting, we ended up doing a hell of a lot better than any other week. Admittedly we had to give a ‘mystery’ presentation about the ethics of a mock killer robot story (the robot turned killer, not designed to be a killer). For those that are interested, the story can be found here. That presentation took the majority of the meeting, which was helpful (in my mind).

That’s all for now.
Robert

15
October

Weekly catchup – Week sixteen

Welcome to week sixteen everyone. It’s been a long and busy week, so I’ll get right into it.

Monday: First day back for term 4, even though it was supposed to be my day off. I went in to work on the robot with one of the guys in my group, who didn’t turn up until 3 hours after we’d organised to meet. I wasn’t bothered, though. It gave me time to work on my chat website (which is coming along quite well, to be honest). When the group member did turn up, we went downstairs within Innova21 (or whatever it’s called now) to get something to eat before going to the BESE lab to work on getting the robot ready for the presentation the next day. Turned out we had a hell of a lot of work to do. Three hours later, we still had a hell of a lot to do.

Tuesday: First early morning for the term. When I got in, the group member I’d met up with the day before was already there! It was a real first to see him working on code that early in the morning. Made me proud. We both continued working on getting the robot ready for the presentation, even while the others in the group were turning up. Unluckily, we broke some things within the robot while getting other things working. Doing all this coding made us late to the meeting, which annoyed the lecturers more than ever. From there, it just went more and more downhill. After the meeting, two group members left (who had other arrangements). The three of us that were left went to get some lunch together before working even more on the robot code, to try and get something done and working. Five hours later (including time we should have been in a lecture), we had a hell of a lot of code written but it still wasn’t completed. Far from it.

Wednesday: I actually got a fairly nice sleep in on Wednesday. By the time I did get up, I only had time to get ready and leave for university. When I got in, I found the same group member I’d seen the past two days working on code doing even more coding! We had a quick chat about what he’d gotten done and what still needed to be done, before I was dragged off by a friend wanting to get to the DS lecture (don’t know why he dragged me, but he did). The lecture this week was the last one for course content, since next week we’re supposed to have a guest lecturer. It was mostly just a wrap up of how the DNS system works, and how and why naming is used in general. It was fairly interesting.

Thursday: Early morning number 2 for term 4. When I got into university I worked a little on getting some tests for the robot code done, and fixing up our code to pass those tests. Half an hour later, I had to stop and get to the OS lecture. We had a new lecturer this week, who seems a fair bit better than the other one (not to be mean). He started on the topic of file systems, which is honestly a hell of a lot more interesting than any other topic we’ve gone through so far. At the end of the first hour, though, the first lecturer came in and took over just to tell us that he wouldn’t be here for the revision lecture and that he’d put up a revision sheet on the course page for us to look over. After he’d finished, we were able to leave early. My group went to the SE lab to continue working on the damn robot. We got a hell of a lot done in the time people were there. Our GUI master (as we call him) was able to get a fair bit of the second version of the panel that displays the map completed. The member I’ve seen nearly every day this week was able to create some images to use within the GUI, then figure out how to use a pre-made pilot system that’s a part of LeJOS to get the robot moving. Another member was able to create a (very buggy) search algorithm. And the other member created quite a few tests for our code. All of this took 6 hours to complete. And we’re still not done! We’re getting really close with the pre-made pilot, though. That should make our code cleaner and simpler, and hopefully work better.

Friday: I had the best sleep in ever on Friday! I didn’t wake up until after 12:30pm, which was really, really nice. During the day I didn’t do too much either. I did work on making more tests for our code and getting more test coverage from the tests. I also created a new map by hand for our robot to traverse, not that we’ve got the code for that done at all. Later on in the day I also worked on my EDC assignment, which is basically done now.

Well, that’s what happened during this busy week of mine. Thanks for reading.
Robert

12
October

Reaper Quicky #14

Hello everyone,

Is it just me, or are there too many blind idiots in the world? Out the front of the central markets in the city there is a pedestrian crossing with a bus light (to let buses go before the rest of the traffic). Every so often my bus out of the city has to wait at that set of lights, and will usually get the bus light to go. Majority of the time that the bus gets the light, there’s at least one person who notices the bus moving and just starts going (without even bothering to check for a green light)!

Has anyone else noticed the increasing number of idiot drivers on the road, or am I seeing things? Post your own experiences with the current state of traffic in the comments below.

Robert

09
October

General catchup

Hello all,

I just thought I’d say a general hello to everyone, and catch you all up on the weekend’s activities before I get into the last three long and busy weeks of university.

My family’s main computer (which was mostly my mother’s) completely died Friday night. So my father and I went out to get her a brand new one. It’s a beast of a machine, even though it’s only an Intel i3. Most of this weekend has been just getting that set up properly, and recovering all the data from the old machine (since the hard drive didn’t die).

I’ve also been spending time working on a side project for my sites. It will be a distributable chat system and website. Basically, you can test out the chat features then (if you like it) create an account with the site and download the source code to install within your own website. It’s currently not that complete, but I think it will work well once I get more time to work on it.

Last thing I’ve been doing is getting my EDC and OS assignments completed. From what I can tell, they both do what they’re supposed to, so I should get high marks for them. We should find out soon enough.

That’s all for my weekend. Thanks for reading.
Robert

05
October

Reaper Quicky #13 – Good vs Good?

Hey all,

I’ve noticed that in most movies, there’s usually a good side and a bad side fighting for whatever the movie’s about. I wonder, is it possible for there to ever be two good sides with conflicting views? Would that make a good movie? What do you all think? Post your opinions in the comments below.

Robert

03
October

Nostalgia Moment

Hey everyone,

Last night I was just sitting around, trolling Facebook and YouTube (since there was nothing on TV), and stumbled across some of the old songs I used to be into. It really took me back to listen to them again. They got me thinking about how much the world’s changed since then. Kids can’t really be kids any more, there’s more security at public events and places, and there’s much more choice for nearly everything. I admit, some of the extra security and choices aren’t bad, but a fair bit of it is just unnecessary and outright stupidity.

Who’s to blame, though? Is it the parents of the current youngest generation (gen X), or is it the generation before that (baby boomers)? Or is it even the generation after (gen Y)? And should we be blaming them, or applauding them? Either way, I don’t think there’s anything we can do to go back to the world we used to live in. But, to be honest, would anyone want to go back? My guess is that a vast majority wouldn’t.

Not everything in the current world is bad, though. Take tertiary study, for example. There are more and more courses popping up, which all lead to slightly different job prospects. That’s a good thing, because that extra choice in what to study allows most people to do what they enjoy as a hobby throughout their lives as a career. Also, the technology jump that’s occurred in the past few years has gotten humanity as a whole a little closer.

Where the world’s going from now, I don’t know. I just hope it doesn’t end up as screwed up as I believe it might.
Robert

01
October

How to: Javascript Functions and Events

Welcome back to another episode in my JavaScript tutorials. I was going to go into how to create your own classes this time, but I realised I haven’t done anything about functions and events. These two topics are more important in being able to create dynamic pages than objects are, so I decided I better go in-depth into these first.

As I’ve already gone over how to define a function, but what can you do with them? Well, just like in any other language, you can use them to split up your routines to take advantage of code reuse. Or, since JavaScript is an event driven language, you can use them as a callback from an event on a HTML element within your page. For example, say you have a link that needs to make something on your page change:

<a href="#">
Change this text to something else
</a>

To make it do what you’d want, you’d create a function like so:

function changeText(element){
   element.innerText="Some new text";
}

Now that you have this function, you need to somehow call it from your link. That’s where events come in. All HTML elements allow for some range of events to be called when they occur on that, or a child, element. One such event is the “click” event. This one seems the most logical for this situation.

Now there are three ways to listen for an event on an element. The first way is through directly embedding it in the HTML, the second is to use the element.onevent attributes, and the third is by using element.addEventListener() (or element.attachEvent() in the case of Internet Explorer browsers after version 5). The first and second options are supported by nearly all browsers for nearly all events, so I’ll deal with only these two from now on.

The function I’ve created above assumes the element will be passed into the function. In the case of the element.onevent attributes, in most browsers an event object is passed into the attached listener function by default and the element itself is passed as the “this” variable. So we can either change the function to allow for that difference, or we can just change the HTML to call our function and pass in the element. This second option seems better. So our link becomes:

<a href="#" onclick="changeText(this);return false;">
Change this text to something else
</a>

This will now call the above function to change the text. The return false part of the listener tells the browser to not perform its default operation, which would be to follow the link to the address it points to.

You are also able to gain access to the event object mentioned above within the HTML onevent attributes, with the variable “event”. In a way, setting the onevent attributes on a HTML element is a little like the declaration:

element.onevent=function(event){
   // value of onevent attribute
}

within JavaScript.

The event object has a moderate list of attributes to tell you about the event that has just occurred, including what keys on the user’s keyboard were pressed when the event occurred, the element involved with the event, and other bits of information about the event itself.

The best way to find out what events you can listen for on any element is by using a JavaScript debugging tool within your browser to obtain an element on your page, and having a look at the attributes it includes. All events have a name starting with “on” (to signify the function will be called “on” that event).

That’s about all for functions and events. Thanks for reading.
Robert