Moodle 2.0 Attendance module fix for use with PostgreSQL

Here you will find a small fix for the attendance module for moodle 2.0. Some queries have problems if the are executed on our PostgreSQL database. So if you get some “group by” errors you could use the following fix. For the module see here
Change query @row 826

SELECT ue.userid, ue.status, ue.timestart, ue.timeend
                      FROM {user_enrolments} ue
                      JOIN {enrol} e ON e.id = ue.enrolid
                     WHERE ue.userid $usql
                           AND e.status = :estatus
                           AND e.courseid = :courseid
                  GROUP BY ue.userid, ue.status, ue.timestart,ue.timeend

and @row 851

SELECT ue.userid, ue.status, ue.timestart, ue.timeend
                  FROM {user_enrolments} ue
                  JOIN {enrol} e ON e.id = ue.enrolid
                 WHERE ue.userid = :uid
                       AND e.status = :estatus
                       AND e.courseid = :courseid
              GROUP BY ue.userid,ue.status, ue.timestart, ue.timeend

have fun

Let’s say hello to our new team member,… Fred

The past days we did some recruiting for our new image processing project…. In the end only one survived Markus selection procedures of hell.

So let’s say hello to Fred.

Fred responsibilities will be:

  • check that we meet our 33fps goal
  • exactly maintaining up to 6 coffee breaks per day
  • check the results of our gain/gamma correction algorithm
  • check the circle ROI (photo) for disharmonies
  • and last but not least motivate our lead programmer Markus

Kinect used for interactive public space advertising

Quite a while ago I wrote about a young aspiring company named Rarebyte. The guys at Rarebyte have a bunch of very innovative ideas  ,… one of them is a new operational area for the Microsoft Kinect platform.

Their idea is to use the Kinect platform with associated middle-ware to create a new way for interactive public space advertising.

The System is installed at the subway station  Stephansplatz in Vienna as part of the (re)branding marketing campaign of A1.

Visitors of the subway station at the Stephansplatz can see themselves with speech and thought bubbles above their heads that contain entertaining and product specific slogans as well as different A1 logos.

But see for yourself 🙂

[youtube GItvRqmuUME]

[youtube fiS_z7sD5sg]

articel at Der Standart -> link

wi-GO a cool Kinect usage to make someone’s life easier

The guys from the University of Beira Interior (Department of Informatics) came up with a wonderful idea how to use the Kinect to  improved quality of life for disabled persons.

The wi-GO project is a robot system based on sensor technology Kinect that enables disabled persons, elderly and pregnant women, .. to carry objects without difficulty, comfortably and safely.

The following video shows the difficulties a person in a wheelchair faces when navigating a shopping cart into a store.

But see for your self 🙂

[vimeo 24542706]

AnatOnMe an Microsoft reseach project for improving patient-doctor communication

I just stumbled over an interesting project done by some Microsoft researchers. AnatOnMe is a projection-enabled mobile device which should help to improve patient-doctor communication in medical contexts.

For example if a patient has a bone injury in his upper thigh, the device will project the image of the bone and surrounding tissue on the the patients skin. This will give the patient an idea of how the injury actually looks,….. cool 🙂

[youtube Zg8RvXe2qTE]

Honeycomb for Tegra 2 based (POV, Vega,….) Tablets

Why….. because we can 🙂 The guys from TeamNewCo and TeamVillain made the first running Honeycomb (VegaComb) port for the Tegra 250 based tablets.

The last evening I reflashed my POV with the VegaComb ROM,… and it works almost flawlessly. If you are interested you can download the stuff from the tabletrons forum.

Just in case you have any trouble installing the ROM.

I started from a fresh 1.09 firmware rev from myadventvega, then installed the recover apk mentioned here, rebooted and recovered from the zipped ROM. .. e volà.. 🙂

And remember if you like it consider to support them with a donation!! 🙂

12.07.2011 – Update….. the newest VegaComb seems to be version beta 1.7 link

have fun! 🙂

Three20 how to use TTTableView within TTScrollView addition

In a current project I came across the situation that I wanted to implement a cool TTScrollView with a few TTTableViews in it.

For some reason in my version of the current Three20 branch the TableView was receiving the “up and down” touch events but the parent view (TTSscrollView) didn’t get any touch events. Googeling give me the result that some of you had the same problem but I couldn’t find any solution for the problem.

So I came up with the following solution for the problem.

I added a new category TTTableView+TouchesMoveAddition:

// UI
 #import "Three20UI/TTNavigator.h"
 #import "Three20UI/TTStyledTextLabel.h"
 #import "Three20UI/UIViewAdditions.h"

// UICommon
 #import "Three20UICommon/UIWindowAdditions.h"

// Style
 #import "Three20Style/TTStyledNode.h"
 #import "Three20Style/TTStyledButtonNode.h"
 #import "Three20Style/TTStyledLinkNode.h"

// Core
 #import "Three20Core/TTCorePreprocessorMacros.h"

#import "TTTableView+TouchesMovedAddition.h"

@implementation TTTableView (TTTableViewDataSourceNIBCapAddition)

- (void)touchesMoved:(NSSet*)touches withEvent:(UIEvent*)event {
 [super touchesBegan:touches withEvent:event];

if ([self.delegate respondsToSelector:@selector(tableView:touchesMoved:withEvent:)]) {
 id<TTTableViewDelegate> delegate = (id<TTTableViewDelegate>)self.delegate;
 [delegate tableView:self touchesMoved:touches withEvent:event];
 }

if (_highlightedLabel) {
 UITouch* touch = [touches anyObject];
 _highlightStartPoint = [touch locationInView:self];
 }
 }
@end

So if you implement the UITableView protocol in your ViewController which holds, for example, your TTScrollView:

- (void)tableView:(UITableView*)tableView touchesBegan:(NSSet*)touches withEvent:(UIEvent*)event{
 tableView.scrollEnabled = NO;
 [_scrollView touchesBegan:touches withEvent:event];

}

- (void)tableView:(UITableView*)tableView touchesMoved:(NSSet*)touches withEvent:(UIEvent*)event{

 [_scrollView touchesMoved:touches withEvent:event];

}

- (void)tableView:(UITableView*)tableView touchesEnded:(NSSet*)touches withEvent:(UIEvent*)event{
 tableView.scrollEnabled = YES;
 [_scrollView touchesEnded:touches withEvent:event];

}

The touch events will be forwarded to the TTScrollView.

Focus on the scrollEnable calls !!!… 🙂

have fun 🙂

Nvidia Tegra ADB driver installation

Since a couple of people ask me about installing the ADB stuff, … here we go.. 🙂

So these is how i managed to get it working.

  1. Remove your POV drivers, these drivers are for rescue stuff.
  2. Install the Latest Android SDK
  3. Open the SDK Manager in “Admin” Mode and download and under “Available Packages” -> “Third party Add-ons” download the “Google USB Driver package.  After installation you will find the ADB driver under “..Android\android-sdk\extras\google\usb_driver”
  4. Goto “..Android\android-sdk\extras\google\usb_driver” and open android_winusb.inf.
    1. Search for [Google.NTx86] and [Google.NTamd64] add

;NVIDIA Tegra

%SingleAdbInterface% = USB_Install, USB\VID_0955&PID_7000

%CompositeAdbInterface% = USB_Install, USB\VID_0955&PID_7100&MI_01 (well spotted Michael 🙂 )

  • Open a shell an execute “echo 0x955>> %USERPROFILE%\.android\adb_usb.ini” (now without post space after hex, well spottet susafi!)
  • Connect your POV to your PC. Open the device manager. Here you should see something like “Nvidia Harmony with a yellow sign.
  • Right-click it and click ‘Update Driver Software..’. -> select to pick from a list device drivers on your computer
  • Browse to the google-usb_driver folder inside your Android SDK folder and select the android_winusb.inf file
  • Now you should see a new section “Android Phone” -> “Android Composite ADB Inteface”
  • Stop – Start you ADB server and check with “adb devices” for your POV. You should see something like

List of devices attached
0270308343a11617        device

One last note, if you have troubles deinstalling your POV driver, you can use “USBDeview”. Just search google for it.

have fun