Coder Social home page Coder Social logo

foster's Introduction

Foster

##Abstract Grabs system and user information in a UWP (Universal Windows Platform) context.

##Goal Foster is a UWP/Windows 10/Windows Store targeted library for gathering both user and system information for the current Win RT device. In order to be compatible with all UWP devices (including Surface, IoT, desktop, Xbox, Phone), Foster only makes use of traditional Win32 calls that are supported by UWP. The final version of this library will gather as much information as it can to create a profile for the logged in user with their account name and avatar, as well as in-depth stats on the hardware and system settings for their device. This profile information will be stored in a struct that can be exported and utilized by other applications.

##Capabilities (AKA App Permissions) Used Your App's package.appxmanifest file will need the following to function properly with the methods defined in Foster.cpp

  • Internet (Client)
  • Removable Storage
  • User Account Information

##API Contracts Used Foster makes use of the following UWP API contracts:

  • Windows.Foundation.FoundationContract
  • Windows.Foundation.UniversalApiContract
  • Windows.UserProfile.UserProfileContract
  • Windows.Devices.Portable.PortableDeviceContract

##Documentation For more detailed documentation visit www.github.com/mindaptiv/Foster/wiki

##Contact [email protected]

foster's People

Contributors

mindaptiv avatar scrubsauce avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar

foster's Issues

Grab XInput Gamepads

Split from #36

Grab and store device metadata in controllerStruct(s) for any attached gamepads that support XInput.

Grab RAM specs

CURRENT REQUIREMENTS:
-return minimum supported RAM size for WinRT

OLD REQUIREMENTS:
-make
-model
-size in bytes as unsigned 64 bit int
-speed 32 bit float in hz
-additional L1/L3 cache information

Grab HID Devices

Grab information on USB controllers (where possible) and store their metadata.

Change DST Values

Reassign value definitions to better fit with "0 is error code" convention.

Convert Variables

-Convert string/wstring to utf8
-Convert various integer types to appropriate for export

Add Error Month

Add error value for months that do not fall between 1-12.

Change Day Values

Reassign integer definitions for days of the week to better fit with "0 is error code" convention.

Status Update 3/5

Hey Jake,

  1. Got my 360 Controllers set aside here to take in tomorrow to test XInput with.
  2. We're now grabbing Keyboard presence in Foster.
  3. Implemented structs for the various HID types we're trying to track.
  4. PointerDevices did not work as expected. When enumerating even with three mice attached my Vector was only returning with one device. I wondered if I was implementing something wrong, so I downloaded MS's sample and I was getting the same results with half a dozen different mice. The types in the breakpoint I was receiving were also a little perplexing. Instead of getting a PointerDevice object I was getting a PointerDeviceServer object, which I can't find in the documentation anywhere. Additionally, the type of the device according to the debugger was POINTER_DEVICE_TYPE_MAX (-1), which a. is an invalid value, b. is only supposed to be returned when I'm coding with the desktop version of this particular class, and c. is not actually being interpreted as POINTER_DEVICE_TYPE_MAX by MS's code (the if logic always goes into the if (value == 1) case, and if I add an if (value == -1), it never goes into that case). Supppper confusing at the time, but I believe that Visual Studio has somehow loaded the Desktop version of the symbols in the debugger rather than the Windows Store versions. Despite multiple efforts, and changes, was not able to get it to detect multiple pointers. Since I'm not sure I can trust the rest of the information being returned at this point in time, I'm going to try to use MouseCapabilities instead, which detects the presence of a mouse, and properties of all the available mice pooled together in one class.

Thanks,
Josh

Grab CPU Hertz Estimate

Posix example:
size_t length;
int mib[6];
int result;

mib[0] = CTL_HW;
mib[1] = HW_CPU_FREQ;
length = Tbytes_u( result );

if( sysctl(mib, 2, &result, &length, NULL, 0 ) < 0 )
{
Log( "Err:getting cpu frequency\n" ); return;
}
Log( "CPU Frequency = %d hz\n", result );

Grab Available Device Information

Retrieve relevant data available for:
-Storage Devices
--Total size
--Free size
-USB Devices
--Controllers, etc.
-Screens
--Make
--Model
--Refresh rate
--Resolution
--Color profile
-Speakers
-Cameras (non depth-sensing)
-Microphones

Device Properties Expected:

  1. Unique ID
  2. Name
  3. Enabled?
  4. Default?
  5. Icon
  6. Physical Device Location

Add 6 basic inputs

Up, Down, Left, Right, Enter, Esc, or equivalent

Add code to testing project (NOT FOR repo push!)

Detect 32 vs. 64 bit OS

Will be used to provide an additional piece of data about system as well as act as a switch for returning minimum values for items like RAM size.

Keep getter functions?

The getter functions were mostly a holdover from school-project habits, they just return the member variable of a given cylonStruct (getUsername(tory) returns the username of tory instead of calling tory.username, etc.). Since I have to refactor the way I'm building labels in DirectX to get data from the new global debugStruct (see #30), now would be a good time to remove them as that is the only place in code they are being called.

Grab CPU specs

-make as utf8
-model as utf8
-no. of cores as unsigned 64-bit int
-speed in hz as 32-bit float

Handle Empty Usernames

Check length of wUsername and set to "0" if empty to better fit with "0 is error code" convention.

Create mouseStruct

Singular struct for use by a cylonStruct for holding pooled mouse properties to replace pointerStruct.

Split from #36

Add Error Date

Add error value for dates that do not fall between 1-31.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.